# Maintainer: Marti Raudsepp <marti@juffo.org>

pkgname=flashbench-git
pkgver=62.2e30b19
pkgver() {
	cd "$srcdir/$pkgname"
	echo $(git rev-list --count master).$(git rev-parse --short master)
}
epoch=1
pkgrel=1
pkgdesc="Tool for benchmarking and classifying flash memory drives"
arch=(i686 x86_64)
license=('unknown')
url="https://lwn.net/SubscriberLink/428584/354d16fe00c90072/"
makedepends=('git')
replaces=('flashbench')
provides=('flashbench')
conflicts=('flashbench')
source=("$pkgname::git://git.linaro.org/people/arnd/flashbench.git")
md5sums=('SKIP')

build() {
  make -C "$srcdir/$pkgname"
}
package(){
  install -Dm755 "$srcdir/$pkgname/flashbench" "$pkgdir/usr/bin/flashbench"
  install -Dm755 "$srcdir/$pkgname/erase" "$pkgdir/usr/bin/flashbench"
}
